<?php

include "connect.php";
$t_attendance_id=$_POST['t_attendance_id'];
$teacher_id=$_POST['teacher_id'];
$date=$_POST['date'];
$present=$_POST['present'];

$sq=mysql_query("select * From teacher_attendance where t_attendance_id='$t_attendance_id'");
while ($row = mysql_fetch_array($sq)) {
$sql=mysql_query("UPDATE teacher_attendance SET t_attendance_id='$t_attendance_id',teacher_id='$teacher_id',date='$date',present='$present'
  where t_attendance_id='$t_attendance_id'");


header("Location:update teacher attendance.php");
}
?>
